<?php

namespace maotool\core\facade;

use maotool\cache\TagSet;
use maotool\core\Container;
use maotool\core\Facade;
use maotool\core\Instance;

/**
 * @see \maotool\core\Cache
 * @package maotool\core
 * @mixin \maotool\core\Cache
 * @method static mixed get(string $key, mixed $default = null)
 * @method static TagSet tags(array $tags)
 * @method static bool has(string $key)
 * @method static mixed pull(string $key, mixed $default = null)
 * @method static bool put(string $key, mixed $value, int $seconds = null)
 * @method static bool replace(string $key, mixed $value, int $seconds = null)
 * @method static bool add(string $key, mixed $value, int $seconds = null)
 * @method static int|bool increment(string $key, int $value)
 * @method static int|bool decrement(string $key, int $value)
 * @method static bool remove(string $key)
 * @method static bool clear()
 */
class Cache extends Facade
{

    /**
     * 获取Facade对应的容器
     * @return Instance
     */
    protected static function getFacadeContainer()
    {
        return Container::getContainer()->getInstanceByClass(\maotool\core\Cache::class);
    }

}